import request from '@/utils/request'

export function fetchList(params) {
  return request({
    url: '/employees',
    method: 'get',
    params: params
  })
}

export function saveEmployees(form) {
  return request({
    url: '/employees',
    method: form.eno ? 'put' : 'post',
    params: form
  })
}

export function deleteEmployees(eno) {
  return request({
    url: '/employees',
    method:  'delete',
    params: {eno:eno}
  })
}

export function addEmployees(employees) {
  return request({
    url: '/employees',
    method:  'post',
    params: employees
  })
}
